<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">

<head>

    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>出价记录</title>

    <link href="../../resource/css/bootstrap.min.css?v=3.3.5" rel="stylesheet"
          th:href="@{/resource/css/bootstrap.min.css?v=3.3.5}"/>
    <link href="../../resource/hotui/css/font-awesome.min.css" th:href="@{/resource/hotui/css/font-awesome.min.css}"
          rel="stylesheet">
    <!-- Morris -->
    <link href="../../resource/hotui/css/plugins/morris/morris-0.4.3.min.css"
          th:href="@{/resource/hotui/css/plugins/morris/morris-0.4.3.min.css}" rel="stylesheet">
    <link href="../../resource/css/animate.min.css" rel="stylesheet" th:href="@{/resource/css/animate.min.css}"/>
    <link href="../../resource/hotui/css/style.min-1.0.8.css" th:href="@{/resource/hotui/css/style.min-1.0.8.css}"
          rel="stylesheet">
    <link href="../../resource/hotui/css/hotui.style.override.css"
          th:href="@{/resource/hotui/css/hotui.style.override.css}" rel="stylesheet"/>

    <style type="text/css">
        .hr-line-dashed {
            margin: 10px 0;
            height: 1px;
            border-top: 1px dashed #e7eaec;
            background-color: #fff;
            color: #fff;
        }
    </style>
</head>

<body>
<div class="wrapper wrapper-content tooltip-demo">
    <!--search-->
    <form role="form" id="searchForm" class="search-panel" method="get">
        <input type="hidden" th:value="${pageIndex}" name="pageIndex"/>
        <input type="hidden" th:value="${productId}" name="productId"/>
        <input type="hidden" th:value="${sessionId}" name="sessionId"/>
    </form>
    <!--search-->

    <!--list-->
    <div class="row">
        <div class="col-lg-12">
            <div class="ibox float-e-margins m-b-none">
                <div class="ibox-content p-xxs no-top-border">

                    <div class="panel-body">
                        <table class="table table-bordered table-hover table-center">
                            <thead>
                            <tr>
                                <th>用户</th>
                                <th>出价金额</th>
                                <th>出价时间</th>
                            </tr>
                            </thead>
                            <tbody>

                            <tr th:each="item:${list}">
                                <td>
                                    <span th:text="${item.userPO.nickName}"></span>
                                    <br>
                                    <span th:text="${item.userPO.mobile}"></span>
                                </td>
                                <td th:text="${item.bidAmount}"></td>
                                <td th:text="${#temporals.format(item.createTime,'yyyy-MM-dd HH:mm:ss')}"></td>
                            </tr>
                            </tbody>
                        </table>
                        <p style="float: left; margin: 20px 0;">
                            共<span th:text="${totalRecords}"></span>条记录，当前第<span th:text="${pageIndex}"></span>/<span
                                th:text="${totalPages==0?1:totalPages}"></span>，每页20条记录
                        </p>
                        <ul style="float: right;" class="pagination pagination-split">
                        </ul>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>

<!--基础框架js-->
<script src="../../resource/js/jquery.min.js?v=2.1.4" th:src="@{/resource/js/jquery.min.js?v=2.1.4}"></script>
<script src="../../resource/js/bootstrap.min.js?v=3.3.5" th:src="@{/resource/js/bootstrap.min.js?v=3.3.5}"></script>
<script src="../../resource/hotui/js/hot/bootstrap.hot.extra-utils.js"
        th:src="@{/resource/hotui/js/hot/bootstrap.hot.extra-utils.js(123123)}"></script>
<script src="../../resource/hotui/js/hot/bootstrap.hot.extra-init.js"
        th:src="@{/resource/hotui/js/hot/bootstrap.hot.extra-init.js}"></script>
<script src="../../resource/hotui/js/content.min.js" th:src="@{/resource/hotui/js/content.min.js}"></script>


<script type="text/javascript" th:inline="javascript">
    const pageIndex = /*[[${pageIndex}]]*/  1;
    const totalPages = /*[[${totalPages}]]*/  0;
    const pageUri = /*[[@{/auction/bidList}]]*/  "";
</script>
<script>
    $(function () {
        //初始化分页
        var pageinate = new hot.paging(".pagination", pageIndex, totalPages, 7);

        pageinate.init(function (p) {
            listHandler.search(p);
        });
    });

    var listHandler = {
        search: function (pageIndex) {
            $("input[name=pageIndex]").val(pageIndex);
            $("#searchForm").submit();
        }
    }
</script>
</body>
</html>
